package com.cctc.juc.demo.Bitc.BwaitAndnotify.Bsynchronized;

/**
 * 临界区，共享资源 [单例] 持有类。
 */
public class ResourceHolder {
    private static class Singleton {
        private static final Resource INSTANCE = new Resource();
    }

    private ResourceHolder() {
    }

    public static Resource getInstance() {
        return Singleton.INSTANCE;
    }

}
